{% extends "base.html" %}

{% block content %}
<!--热门电影-->

<!--热门电影-->
<!--电影列表-->
<section id="movielist">
    <div class="container2">
        <input type="text" class="playlist" value="[]" hidden>
        <div class="row wow fadeIn box videolist" data-wow-delay="0.6s" style="position: relative;width: 100%;">
            <div class="col-md-12 table-responsive"></div>
            {% for v in page_data %}
            <div class="col-md-3 item" style="position: relative;">
                <div class="movielist text-center" id="{{v.id}}" style="cursor: pointer;width: 100%;height: 100%;background-color: #292929;">
                   <div class="icon-del" onclick="del(this)"></div>
                    <img src="Images/{{ v.logo if v.logo else '' }}" style="min-width: 262px;min-height: 180px;width: 100%;background: aquamarine;" id="{{v.id}}" onclick="play(this)" class="img-responsive center-block" alt="">
                    <div style="float: left;color: blue;position: relative;">{% if v.ftype != "m3u8" %}{{ v.ftype }}{% end %}</div>
                    <div style="float: left;color: #ff9900;position: relative;width: 25px;text-align: left;">{% if len(v.indexname.split(' '))>1 %}cut {% end %}</div>
                    <div class="text-left"  id="{{v.id}}" onclick="play(this)" style="margin-left:auto;margin-right:auto;">
                        <span title="{{ v.name }}" style="color:#999;font-style: italic;text-overflow: ellipsis;overflow: hidden;white-space: nowrap;display: block;">{{ v.name }}</span><br>
                    </div>
                </div>
            </div>
            {% end %}
        </div>
    </div>
</section>

{% end %}

{% block js %}
<script>
    //初始化
    window.onload = function(){
        var data = {{ page_data }};
        var ids = [];
        for(var i in data){
            ids.push(data[i].id);
        }
        $('.playlist').attr('value',JSON.stringify(ids));
    }
</script>
<script type="text/javascript">
    
</script>
<!--电影列表-->
{% end %}